package com.gwd.task.services;

import com.gwd.task.model.CodeSubmitRecordDTO;
import com.gwd.task.model.PageUtils;
import com.gwd.task.model.ProductionEventsDTO;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;

import java.util.List;

/**
 * @author zhiyongming
 * @date 2020/12/2 18:03
 */
public interface ProductionEventsServer {

    PageUtils findByPage(ProductionEventsDTO dto, PageUtils page);

    void save(ProductionEventsDTO dto, Long id);
    HSSFWorkbook export(ProductionEventsDTO dto);

    void remove(Long id);

    ProductionEventsDTO findById(Long peId);
    List<ProductionEventsDTO> findAllById(List<Long> ids);
    List<ProductionEventsDTO> findByUserIdListAndUnClose(List<Long> ids);

    //-----状态切换-----
    void start(Long peId, Long userId);
    void restart(Long peId, Long userId);
    void submit(Long peId, Long userId, CodeSubmitRecordDTO csrDTO);
    void test(Long peId, Long userId);
    void finish(Long peId, Long userId);
    void close(Long peId, Long userId);

    void board(List<Long> ids);

    //-----修改人员------
    void changeDevPerson(Long peId, Long userId);
    void changeTestPerson(Long peId, Long userId);
}
